-
Notifications
You must be signed in to change notification settings - Fork 178
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chore: Supports running cloud gov tests in CI #2302
Conversation
2. Use the [`acc.ConfigGovProvider`](https://github.com/mongodb/terraform-provider-mongodbatlas/blob/CLOUDP-250271_cloud_gov/internal/testutil/acc/provider.go#L61) together with your normal terraform config | ||
3. Modify the `checkExist` and `CheckDestroy` to use `acc.ConnV2UsingGov` | ||
4. Follow naming convention: | ||
1. `TestAccGovProject_withProjectOwner`, note prefix: `TestAccGov` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
1. `TestAccGovProject_withProjectOwner`, note prefix: `TestAccGov` | |
1. `TestAccProject_govWithProjectOwner`, note prefix: `TestAccGov` |
not a strong opinion but like the idea of leaving the first part before the underscore only with the resource, and second part giving detail of the test case (as shown in tf docs)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think using it in the first part makes regex
selection simpler.
Although with this approach it might not be necessary 🤔 WDYT?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think using it in the first part makes regex selection simpler
Not sure if I understand this point given we wont need to identify gov tests from others
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good discussion. Added a bit more context in c888aff
Description
Supports running cloud gov tests in CI.
Follow-up PR with a gov migration and acceptance test: #2291
Solution discussion
Uses a fully configured provider when using cloud-gov, why?
Alternatives considered:
t.Setenv("MONGODB_ATLAS_LAST_VERSION", "1.2.3")
but with MONGODB_ATLAS_PRIVATE/PUBLIC_KEY/BASE_URL++Link to any related issue(s): CLOUDP-250271
Type of change:
Required Checklist:
Further comments